ob_start(); header("Cache-Control: no-store, no-cache, must-revalidate"); // HTTP/1.1 header("Cache-Control: post-check=0, pre-check=0", false); header("Pragma: no-cache"); require("../conf/sqlconf.php"); require("../conf/session.php"); // HTTP/1.0 sessionSecurityControl(); ob_end_flush(); if (empty($id_vote)) { echo("Vous dévez renseigner le paramètre id_vote..."); exit; } $vote = new Vote; if (!$vote->dbRead($id_vote)) { echo("Impossible de lire le vote $id_vote en base..."); exit; } if ($HTTP_POST_VARS) { if ($vote->type_vote=='unique') { if (!empty($id_item)) { $vote->setVote($membre_session->id_membre,$id_item); } else { $message = "Vous devez effectuer votre choix"; } } else { $trouve = false; foreach ( array_keys($vote->items) as $key ) { if ($$key=="OK") { $vote->setVote($membre_session->id_membre,$key); $trouve = true; } } if (!$trouve) $message = "Vous devez effectuer votre choix"; } } ?>
print($common_header); ?>Nombre de votants : print($vote->nb_votant); ?> Nombre de votes : print($vote->nb_votes); ?> Nombre de votes blancs : print($vote->nb_votant_blanc); ?>
Nombre de votes |
if ($vote->type_vote=='unique')
{?>
Pourcentage
}
else
{?>
Pourcentage / nb votes }?> |
if ($vote->type_vote!='unique') {?> |
Pourcentage / nb votants |
}?> | |
print("".$vote->items[$key]->titre_item.""); ?> | print("".$vote->items[$key]->nb_votes.""); ?> | print("".$vote->items[$key]->pourcentage." %"); ?> | if ($vote->type_vote!='unique') {?> | print("".$vote->items[$key]->pourcentageVotant." %"); ?> | }?> |